package com.woniuxy.businessassembly.controller;

import com.woniuxy.businessassembly.form.ServerForm;
import com.woniuxy.businessassembly.model.HotelServer;
import com.woniuxy.businessassembly.service.IHotelServerService;
import com.woniuxy.common.Result;
import com.woniuxy.hotel.api.ServiceProvided;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.List;

/**
 * @author kevin kwok
 * @create 2021-05-25 10:10
 */
@Slf4j
@RestController
public class ServiceProvidedController implements ServiceProvided {
    @Resource
    private IHotelServerService serverService;

    /*查看酒店提供哪些设施*/
    @Override
    public Result queryAllFacilities(String hotelName) {
        List<ServerForm> serverForms = serverService.queryAllServerByName(hotelName);
        return new Result(true,"查询成功",serverForms);
    }

}
